package com.cskaoyan.mall.promo.api;

import com.cskaoyan.mall.dto.ProductDetailRequest;
import com.cskaoyan.mall.dto.ProductDetailResponse;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient("duolai-shopping")
public interface ProductApi {
    /*
     该方法是商品服务暴露给秒杀服务，使秒杀服务获取秒杀商品详情
 */
    @PostMapping(value = "/promo/rpc/detail")
    ProductDetailResponse getProductDetail(@RequestBody ProductDetailRequest request);
}
